<!doctype html>
<html lang="en">
	<head>
		<title>JavaScript Patterns</title>
		<meta charset="utf-8">
	</head>
	<body>
		<script>
			/* Title: The Problem with Globals
			 * Description: You can pass some global objects inside a function.
			 */

			(function ($, YAHOO) {
				// now have access to globals jQuery (as $) and YAHOO in this code
			}(jQuery, YAHOO));

			// References
			// http://www.adequatelygood.com/JavaScript-Module-Pattern-In-Depth.html
		</script>
	</body>
</html>